@extends("fontend.master")
@section("content")
	@if(Session::has('mess'))
			<div class="alert alert-success" role="alert">{{Session::get('mess')}}</div>
	@endif
	<div class="row center">
		@foreach($products as $product)
		  <div class="col-sm-6 col-md-4 leftcate">
		    <div class="thumbnail">
		      <img src="{{$product->img}}" alt="...">
		      <div class="caption">
		        <h3>{{$product->title}}</h3>
		        <p>Giá: <span style="color:red">{{Currency::format($product->price,'VND','')}} VNĐ</span></p>
		        <p><a href="{{URL::route('add_cart',array($product->id))}}" class="btn btn-warning" role="button" >Đặt mua</a> </p>
		      </div>
		    </div>
		  </div>
		@endforeach
	</div>
	
	<div align="center">{{$products->links()}}</div>
@endsection